Carbon


GetThemeWindowRegion

Header: Appearance.h Carbon status: Supported

Obtains the specified window region.

OSStatus GetThemeWindowRegion (
    ThemeWindowType flavor, 
    const Rect *contRect, 
    ThemeDrawState state, 
    const ThemeWindowMetrics *metrics, 
    ThemeWindowAttributes attributes, 
    WindowRegionCode winRegion, 
     rgn
);
flavor

A value of type ThemeWindowType. Pass a constant specifying the type of window to be examined. See “Theme Window Type Constants” for descriptions of possible values.

contRect

A pointer to a structure of type Rect. Before calling GetThemeWindowRegion, set the rectangle to the content area of the window, specified in coordinates local to the current port.

state

A value of type ThemeDrawState. Pass a constant—either kThemeStateActive or kThemeStateInactive—appropriate to the current state of the window. See “Theme Draw State Constants” for descriptions of these values.

metrics

A pointer to a structure of type ThemeWindowMetrics. Before calling GetThemeWindowRegion, set the structure to contain information describing the window.

attributes

A value of type ThemeWindowAttributes. Pass one or more constants corresponding to the window’s current visual attributes. See “Theme Window Attribute Constants” for descriptions of possible values. Pass 0 if the window has none of the enumerated attributes.

winRegion

A value of type WindowRegionCode. Pass a constant specifying the region of the window whose dimensions you wish to obtain.

rgn

A value of type RgnHandle. Pass a handle to a valid region. On return, the region represents the actual region requested.

function result

A result code.

DISCUSSION

The GetThemeWindowRegion function obtains the dimensions of the specified window region under the current theme.

VERSION NOTES

This function is available with Appearance Manager 1.1 and later.

AVAILABILITY

Supported in Carbon. Available in Mac OS 8.1 and later when Carbon 1.0.2 or later is present.


© 2000 Apple Computer, Inc. — (Last Updated 5/8/2000)